{% extends 'layout.twig' %}

{% block main %}
    <div class="container">
        <div class='fm-login-wrap'>
            <h1 class="pg-title">UNIBOX</h1>

            <div class="login_inner_box">
                <div class='login-title'>
                    <span class='login-title-desc'>{{ op_name }}</span>
                </div>

                <form class="fm-login" class="login-body" role="form" method="post" action="">
                    <div class="form-group">
                        <label class="control-label" for="username">用户</label>
                        <input placeholder="邮箱 / 手机号" id="username" name="username" type="text"
                               class="form-control wx-login-ctrl">
                    </div>

                    <div class="form-group">
                        <label class="control-label" for="password">密码</label>
                        <input placeholder="密码长度为6~20位" id="password" name="password" type="password"
                               class="form-control wx-login-ctrl" maxlength="20">
                    </div>

                    <input type='hidden' name='token' value='{{ access_token }}'>

                    <div class="btn_group clear">

                        {% if is_reg is defined %}
                        <input type="button" value="立即注册" id="btn_register" class="btn btn-primary">
                        <a id="btn_show_login" class='btn btn-default btn-sm' href="/?act=login">返回登录</a>
                        {% else %}
                        <input type="button" value="登录" id="btn_login" class="btn btn-success">
                        <a id="btn_show_register" class='btn btn-default btn-sm' href="/?act=register">注册用户</a>
                        {% endif %}

                    </div>

                </form>

            </div>
        </div>
    </div>
{% endblock %}
